cmake_minimum_required(VERSION 3.15)
project(simnow-test)

set(CMAKE_CXX_STANDARD 17)
include_directories(${CMAKE_SOURCE_DIR}/deps/)
include_directories(${CMAKE_SOURCE_DIR}/deps/api)
include_directories(${CMAKE_SOURCE_DIR}/deps/json)
include_directories(${CMAKE_SOURCE_DIR}/deps/http)
include_directories(${CMAKE_SOURCE_DIR}/deps/breakpad/src)

include_directories(/usr/local/include /usr/include )
link_directories(${CMAKE_SOURCE_DIR}/deps/api)
link_directories(${CMAKE_SOURCE_DIR}/deps/breakpad/lib)
link_directories(${CMAKE_BINARY_DIR}/deps/lolog)

add_subdirectory(${CMAKE_SOURCE_DIR}/deps/lolog)
add_executable(server ${CMAKE_SOURCE_DIR}/src/server.cpp ${CMAKE_SOURCE_DIR}/src/MdSpiImpl.cpp)
target_link_libraries(server -lthostmduserapi_se -lthosttraderapi_se -lpthread -lgflags libbreakpad_client.a -llolog)

add_executable(client ${CMAKE_SOURCE_DIR}/src/client.cpp)
target_link_libraries(client -lpthread -lgflags libbreakpad_client.a)

